.class Lcom/estrongs/android/taskmanager/t;
.super Lcom/estrongs/android/taskmanager/tools/d;


# instance fields
.field final synthetic a:Lcom/estrongs/android/taskmanager/CacheManWrapper;


# direct methods
.method constructor <init>(Lcom/estrongs/android/taskmanager/CacheManWrapper;)V
    .locals 0

    iput-object p1, p0, Lcom/estrongs/android/taskmanager/t;->a:Lcom/estrongs/android/taskmanager/CacheManWrapper;

    invoke-direct {p0}, Lcom/estrongs/android/taskmanager/tools/d;-><init>()V

    return-void
.end method


# virtual methods
.method public onGetStatsCompleted(Landroid/content/pm/PackageStats;Z)V
    .locals 6

    iget-wide v0, p1, Landroid/content/pm/PackageStats;->cacheSize:J

    const-wide/16 v2, 0x0

    cmp-long v0, v0, v2

    if-gtz v0, :cond_1

    iget-object v0, p0, Lcom/estrongs/android/taskmanager/t;->a:Lcom/estrongs/android/taskmanager/CacheManWrapper;

    iget-object v0, v0, Lcom/estrongs/android/taskmanager/CacheManWrapper;->mList:Ljava/util/List;

    iget-object v1, p0, Lcom/estrongs/android/taskmanager/t;->a:Lcom/estrongs/android/taskmanager/CacheManWrapper;

    iget-object v1, v1, Lcom/estrongs/android/taskmanager/CacheManWrapper;->currentAppInfo:Landroid/content/pm/ApplicationInfo;

    invoke-interface {v0, v1}, Ljava/util/List;->remove(Ljava/lang/Object;)Z

    move-result v0

    if-eqz v0, :cond_1

    iget-object v0, p0, Lcom/estrongs/android/taskmanager/t;->a:Lcom/estrongs/android/taskmanager/CacheManWrapper;

    iget-object v0, v0, Lcom/estrongs/android/taskmanager/CacheManWrapper;->pkgStatsMap:Ljava/util/HashMap;

    iget-object v1, p1, Landroid/content/pm/PackageStats;->packageName:Ljava/lang/String;

    invoke-virtual {v0, v1}, Ljava/util/HashMap;->get(Ljava/lang/Object;)Ljava/lang/Object;

    move-result-object v0

    if-eqz v0, :cond_0

    iget-object v1, p0, Lcom/estrongs/android/taskmanager/t;->a:Lcom/estrongs/android/taskmanager/CacheManWrapper;

    iget-wide v2, v1, Lcom/estrongs/android/taskmanager/CacheManWrapper;->totalCacheSize:J

    iget-object v0, p0, Lcom/estrongs/android/taskmanager/t;->a:Lcom/estrongs/android/taskmanager/CacheManWrapper;

    iget-object v0, v0, Lcom/estrongs/android/taskmanager/CacheManWrapper;->pkgStatsMap:Ljava/util/HashMap;

    iget-object v4, p1, Landroid/content/pm/PackageStats;->packageName:Ljava/lang/String;

    invoke-virtual {v0, v4}, Ljava/util/HashMap;->get(Ljava/lang/Object;)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Landroid/content/pm/PackageStats;

    iget-wide v4, v0, Landroid/content/pm/PackageStats;->cacheSize:J

    sub-long/2addr v2, v4

    iput-wide v2, v1, Lcom/estrongs/android/taskmanager/CacheManWrapper;->totalCacheSize:J

    :cond_0
    iget-object v0, p0, Lcom/estrongs/android/taskmanager/t;->a:Lcom/estrongs/android/taskmanager/CacheManWrapper;

    invoke-virtual {v0}, Lcom/estrongs/android/taskmanager/CacheManWrapper;->onDataPrepared()V

    :cond_1
    return-void
.end method
